home *** CD-ROM | disk | FTP | other *** search
/ Language/OS - Multiplatform Resource Library / LANGUAGE OS.iso / gnu / autoconf.lha / autoconf-1.4 / Makefile.in < prev    next >
Makefile  |  1993-05-08  |  4KB  |  139 lines

  1. # Makefile for Autoconf.
  2. # Copyright (C) 1992, 1993 Free Software Foundation, Inc.
  3.  
  4. # This program is free software; you can redistribute it and/or modify
  5. # it under the terms of the GNU General Public License as published by
  6. # the Free Software Foundation; either version 2, or (at your option)
  7. # any later version.
  8.  
  9. # This program is distributed in the hope that it will be useful,
  10. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  12. # GNU General Public License for more details.
  13.  
  14. # You should have received a copy of the GNU General Public License
  15. # along with this program; if not, write to the Free Software
  16. # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  17.  
  18. #### Start of system configuration section. ####
  19.  
  20. srcdir = @srcdir@
  21. VPATH = @srcdir@
  22.  
  23. INSTALL = @INSTALL@
  24. INSTALL_PROGRAM = @INSTALL_PROGRAM@
  25. INSTALL_DATA = @INSTALL_DATA@
  26. MAKEINFO = makeinfo
  27. M4 = m4
  28.  
  29. prefix = /usr/local
  30. exec_prefix = $(prefix)
  31.  
  32. # Directory in which to install autoconf script.
  33. bindir = $(exec_prefix)/bin
  34.  
  35. # Directory in which to install m4 files.
  36. datadir = $(prefix)/lib
  37.  
  38. # Directory in which to install documentation info files.
  39. infodir = $(prefix)/info
  40.  
  41. #### End of system configuration section. ####
  42.  
  43. SHELL = /bin/sh
  44.  
  45. DISTFILES = README Makefile.in INSTALL NEWS COPYING ChangeLog \
  46. autoconf.texi autoconf.info* standards.texi make-stds.texi standards.info* \
  47. texinfo.tex acconfig.h autoconf.sh acgeneral.m4 acspecific.m4 \
  48. configure autoconf.in autoheader.sh
  49.  
  50. all: autoconf autoheader autoconf.info standards.info
  51.  
  52. editsh = sed -e 's,@datadir@,$(datadir),g' -e 's,@M4@,$(M4),g'
  53.  
  54. autoconf: autoconf.sh
  55.     rm -f $@
  56.     $(editsh) $(srcdir)/autoconf.sh > $@ && chmod +x $@
  57. autoheader: autoheader.sh
  58.     rm -f $@
  59.     $(editsh) $(srcdir)/autoheader.sh > $@ && chmod +x $@
  60.  
  61. configure: autoconf.conf
  62.     rm -f $(srcdir)/configure
  63.     ln $(srcdir)/autoconf.conf $(srcdir)/configure
  64.  
  65. Makefile: Makefile.in
  66.     sh config.status
  67.  
  68. # Special rule for non-GNU makes.
  69. autoconf.conf: autoconf.in acgeneral.m4 acspecific.m4
  70.     $(M4) $(srcdir)/acgeneral.m4 $(srcdir)/acspecific.m4 $(srcdir)/autoconf.in > $(srcdir)/autoconf.conf
  71.     chmod +x $(srcdir)/autoconf.conf
  72.  
  73. autoconf.info: autoconf.texi
  74.     $(MAKEINFO) -I$(srcdir) $(srcdir)/autoconf.texi --no-split --output=$@
  75. standards.info: standards.texi make-stds.texi
  76.     $(MAKEINFO) -I$(srcdir) $(srcdir)/standards.texi --no-split --output=$@
  77.     
  78. # GNU make rules to produce current foo.conf and foo.h files from all the
  79. # foo.in files in the current directory.
  80. # Don't use := because non-GNU makes reject it.
  81. infiles = $(wildcard [a-z]*.in)
  82. confs: $(infiles:.in=.conf)
  83. heads: $(infiles:.in=.h)
  84.  
  85. # GNU make rule to make a .conf file from a .in file in the current directory.
  86. %.conf: %.in acgeneral.m4 acspecific.m4
  87.     $(M4) $(srcdir)/acgeneral.m4 $(srcdir)/acspecific.m4 $< > $@ && chmod +x $@
  88.  
  89. check:
  90.  
  91. install: autoconf autoheader acgeneral.m4 acspecific.m4 autoconf.info \
  92. standards.info acconfig.h
  93.     $(INSTALL_PROGRAM) autoconf $(bindir)/autoconf
  94.     $(INSTALL_PROGRAM) autoheader $(bindir)/autoheader
  95.     test -d $(datadir) || mkdir $(datadir)
  96.     $(INSTALL_DATA) $(srcdir)/acgeneral.m4 $(datadir)/acgeneral.m4
  97.     $(INSTALL_DATA) $(srcdir)/acspecific.m4 $(datadir)/acspecific.m4
  98.     $(INSTALL_DATA) $(srcdir)/acconfig.h $(datadir)/acconfig.h
  99.     test ! -r $(srcdir)/aclocal.m4 || $(INSTALL_DATA) $(srcdir)/aclocal.m4 $(datadir)/aclocal.m4
  100.     test -d $(infodir) || mkdir $(infodir)
  101.     $(INSTALL_DATA) $(srcdir)/autoconf.info $(infodir)/autoconf.info
  102.     $(INSTALL_DATA) $(srcdir)/standards.info $(infodir)/standards.info
  103.  
  104. uninstall:
  105.     rm -f $(bindir)/autoconf $(bindir)/autoheader
  106.     cd $(datadir); rm -f acgeneral.m4 acspecific.m4 aclocal.m4 acconfig.h
  107.     -rmdir $(datadir)
  108.     cd $(infodir); rm -f autoconf.info standards.info
  109.  
  110. clean:
  111.     rm -f *.conf autoconf autoheader
  112.     rm -f *.aux *.cp *.cps *.dvi *.fn *.fns *.ky *.kys *.log
  113.     rm -f *.pg *.pgs *.toc *.tp *.tps *.vr *.vrs
  114.  
  115. mostlyclean: clean
  116.  
  117. distclean: clean
  118.     rm -f Makefile config.status
  119.  
  120. realclean: distclean
  121.     rm -f TAGS *.info*
  122.  
  123. TAGS:
  124.     etags *.m4 *.sh [a-z]*.in *.texi
  125.  
  126. dist: Makefile $(DISTFILES)
  127.     echo autoconf-`sed -e '/define(AC_ACVERSION,/!d' -e 's/[^0-9.]*\([0-9.]*\).*/\1/' -e q acgeneral.m4` > .fname
  128.     rm -rf `cat .fname`
  129.     mkdir `cat .fname`
  130.     for file in $(DISTFILES); do \
  131.       ln $$file `cat .fname` \
  132.         || cp -p $$file `cat .fname`; \
  133.     done
  134.     tar chzf `cat .fname`.tar.z `cat .fname`
  135.     rm -rf `cat .fname` .fname
  136.  
  137. # Prevent GNU make v3 from overflowing arg limit on SysV.
  138. .NOEXPORT:
  139.